package com.x.erp.model;

import java.util.Date;

import com.x.erp.model.vo.ContractVO;
import org.springframework.format.annotation.DateTimeFormat;

import com.x.framework.annotation.MappingColumn;
import com.x.framework.annotation.MappingTable;
import com.x.framework.model.BaseObject;

@MappingTable(tableName = "ERP_CONTRACT")
public class Contract extends BaseObject {

	private static final long serialVersionUID = 7614858775639820148L;
	@MappingColumn(columnName = "CONTRACT_ID", columnPk = true, columnLength = 32)
	private String contractId;

	@MappingColumn(columnName = "CONTRACT_NO")
	private String contractNo;

	@DateTimeFormat(pattern = "yyyy-MM-dd")
	@MappingColumn(columnName = "CONTRACT_START_DATE")
	private Date contractStartDate;

	@DateTimeFormat(pattern = "yyyy-MM-dd")
	@MappingColumn(columnName = "CONTRACT_ENDING_DATE")
	private Date contractEndingDate;

	@MappingColumn(columnName = "CONTRACT_STATE")
	private Integer contractState;

	@DateTimeFormat(pattern = "yyyy-MM-dd")
	@MappingColumn(columnName = "CONTRACT_CRASH_DATE")
	private Date contractCrashDate;

	@MappingColumn(columnName = "CONTRACT_CREATE_TIME")
	private Date contractCreateTime;

	@MappingColumn(columnName = "CONTRACT_UPDATE_TIME")
	private Date contractUpdateTime;

	@MappingColumn(columnName = "MARKET_ID")
	private String marketId;

	@MappingTable(tableName = "ERP_MARKET")
	private Market market;

	@MappingColumn(columnName = "SHOP_ID")
	private String shopId;

	@MappingTable(tableName = "ERP_SHOP")
	private Shop shop;

	private ContractVO contractVO;// 车系

	public String getContractId() {
		return contractId;
	}

	public void setContractId(String contractId) {
		this.contractId = contractId;
	}

	public String getContractNo() {
		return contractNo;
	}

	public void setContractNo(String contractNo) {
		this.contractNo = contractNo;
	}

	public Date getContractStartDate() {
		return contractStartDate;
	}

	public void setContractStartDate(Date contractStartDate) {
		this.contractStartDate = contractStartDate;
	}

	public Date getContractEndingDate() {
		return contractEndingDate;
	}

	public void setContractEndingDate(Date contractEndingDate) {
		this.contractEndingDate = contractEndingDate;
	}

	public Integer getContractState() {
		return contractState;
	}

	public void setContractState(Integer contractState) {
		this.contractState = contractState;
	}

	public Date getContractCreateTime() {
		return contractCreateTime;
	}

	public void setContractCreateTime(Date contractCreateTime) {
		this.contractCreateTime = contractCreateTime;
	}

	public Date getContractUpdateTime() {
		return contractUpdateTime;
	}

	public void setContractUpdateTime(Date contractUpdateTime) {
		this.contractUpdateTime = contractUpdateTime;
	}

	public Date getContractCrashDate() {
		return contractCrashDate;
	}

	public void setContractCrashDate(Date contractCrashDate) {
		this.contractCrashDate = contractCrashDate;
	}

	public String getShopId() {
		return shopId;
	}

	public void setShopId(String shopId) {
		this.shopId = shopId;
	}

	public String getMarketId() {
		return marketId;
	}

	public void setMarketId(String marketId) {
		this.marketId = marketId;
	}

	public Market getMarket() {
		return market;
	}

	public void setMarket(Market market) {
		this.market = market;
	}

	public Shop getShop() {
		return shop;
	}

	public void setShop(Shop shop) {
		this.shop = shop;
	}

	public ContractVO getContractVO() {
		return contractVO;
	}

	public void setContractVO(ContractVO contractVO) {
		this.contractVO = contractVO;
	}
}
